<%--
$Id: orders-index.jsp 13 2010-11-02 15:35:59Z feigme $
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<title>Orders</title>
</head>
<body>
    <table>
        <tr>
            <th>ID</th>
            <th>Client</th>
            <th>Amount</th>
            <th>Actions</th>
        </tr>
        <c:forEach var="order" items="${orders}">
        <tr>
            <td><c:out value="${order.id}"/></td>
            <td><c:out value="${order.clientName}"/></td>
            <td><c:out value="${order.amount}"/></td>
            <td><a href="${ctx }/example/orders/<c:out value="${order.id}"/>">View</a> |
                <a href="${ctx }/example/orders/<c:out value="${order.id}"/>/edit">Edit</a> |
                <a href="${ctx }/example/orders/<c:out value="${order.id}"/>/delete">Delete</a></td>
        </tr>
        </c:forEach>
    </table>
    <a href="${ctx}/example/orders/new">Create a new order</a>
</body>
</html>
	